<template>
  <div class="nav-bar">
    <div class="left">
      <slot name="left"> 
        <div class="arrow" @click="handleSkipPage"></div>
      </slot>
    </div>
    <div class="center"><slot name="center"></slot></div>
    <div class="right"><slot name="right"></slot></div>
  </div>
</template>

<script>
export default {
  methods: {
    handleSkipPage() {
      this.$router.back()
    }
  }
};
</script>
<style lang="less" scoped>
.nav-bar {
  display: flex;
  align-items: center;
  height: 44px;
  text-align: center;
  background-color: #3190e8;
  font-size: 15px;
}

.left,
.right {
  width: 60px;
}
.left .arrow {
  
    width: 10px;
    height: 10px;
    border-top: 2px solid #ffffff;
    border-left: 2px solid #ffffff;
    margin-left: 10px;
    transform: rotate(-45deg);
}
.center {
  flex: 1;
  font-weight: 700;
  font-size: 18px;
  color: #ffffff;
}
</style>